Controllers used for controlling operations of machinery, equipment, or the like include general-purpose PLCs, and program control controllers dedicated to individual machines, for example.
A PLC is configured from, for example, a plurality of units such as a CPU (Central Processing Unit) unit that includes a microprocessor for executing control programs, and an IO (Input/Output) unit that handles signal inputs from an external switch or a sensor and signal outputs to an external relay device or an actuator. The PLC executes control operation while exchanging data through a PLC system bus and/or a field network between the units for each control program execution cycle.
The controller support apparatus is used for generating various types of setting information for control programs to be executed by a controller or for the controller, and transferring the setting information to the controller. The controller support apparatus is configured by, for example, installing a controller support program on a general-purpose computer. The controller support apparatus includes, for example, an editor function of generating a source list of a control program, a compiler function of generating, from the source list of the controller program, an object program that operates on a controller, a controller simulator function of performing test execution of the control program at the controller support apparatus, and a function of communicating with the controller.
At the development stage of a control program, it is necessary to know the execution time required for the controller to execute the control program. This execution time of the control program is referenced when setting the interval of the execution cycle of the control program. Also, when setting mutually different execution priorities and execution cycle intervals for a plurality of control programs to be executed by the controller, the execution time of each control program is referenced.
In many cases, hardware and the operation system relating to execution of the control program differ between the controller support apparatus and the controller. Also, the execution code of the control program for a simulator may be different from that for a controller. Therefore, the execution time of a control program executed by the simulator of the controller support apparatus may be different from the execution time of the control program executed by the controller.
JP 2001-209411A (Patent Document 1) discloses a method in which the execution time required when a control program is executed by a PLC is obtained at a PLC support apparatus. Specifically, a method is disclosed in which actual process time data at the PLC for each command used in the control program is prepared, and each time a command is processed in a program simulation execution process at a simulator, the actual process time data is referenced and the actual process time corresponding to the command is accumulated.